<?php
include_once("../../service/specialProductService.php");

$name = $_POST["name"];
$names = $_POST["names"];
$speProId = $_POST["speProId"];
 
if(isset($name)){
    deleteImageOfSpecialProduct($name, $speProId);
} else if(isset($names)){
    $arrayNames = split(",", $names);
    
    foreach($arrayNames as $each){
        deleteImageOfSpecialProduct($each, $speProId);    
    }
}
?>